<!doctype html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <meta name="theme-color" content="#000000">
    <!--
      manifest.json provides metadata used when your web app is added to the
      homescreen on Android. See https://developers.google.com/web/fundamentals/engage-and-retain/web-app-manifest/
    -->
    <link rel="manifest" href="{{cdnHost}}/manifest.json">
    <link rel="shortcut icon" href="{{cdnHost}}/favicon.ico">
    <title>{{title}}</title>
</head>

<body>
    <noscript>
      You need to enable JavaScript to run this app.
    </noscript>
    <div id="root" style="height:100%"></div>
</body>
<script src="https://as.alipayobjects.com/g/component/fastclick/1.0.6/fastclick.js"></script>
<script type="text/javascript" src="http://api.map.baidu.com/api?v=2.0&ak=Evwx2C0VlnHXXb3XfuqOvKAMdlXUAMHO"></script>
<script>
    if ('addEventListener' in document) {
        document.addEventListener('DOMContentLoaded', function() {
            FastClick.attach(document.body);
        }, false);
    }

    function getOpenId(){
        let openid = window.localStorage.getItem('openid');
        console.log(openid);
        if (openid == undefined || openid == ''){
            let newopenid = "{{openid}}";
            let url = encodeURIComponent(window.location.href);

            if (newopenid != undefined){
                window.localStorage.setItem('openid',newopenid);
            }

            if (newopenid == undefined || newopenid == ''){
                window.location.href = `http://jyx.7chejian.com/auth?redirect=${url}`
            }
        }
    }

    getOpenId();

</script>
<script src="{{cdnHost}}/js/bundle.js"></script>
<script src="http://res.wx.qq.com/open/js/jweixin-1.2.0.js"></script>
{# <script src="{{cdnHost}}/js/main.951e31d4.js"></script> #}

</html>
